from PIL import Image, ImageFilter

jpg9 = Image.open('9.jpg')

print(jpg9.size)
# 旋转图片
# rotate = jpg9.rotate(90)
# rotate.save('9_rotate.jpg')
# 修改图片大小
# resize = jpg9.resize((100, 500))
# resize.save('9_double.jpg')

# 滤镜
# 模糊滤镜：img.filter(ImageFilter.BLUR)
# 锐化滤镜：img.filter(ImageFilter.SHARPEN)
# 浮雕滤镜：img.filter(ImageFilter.EMBOSS)
# 边缘检测滤镜：img.filter(ImageFilter.FIND_EDGES)
img9_blur = jpg9.filter(ImageFilter.FIND_EDGES)
img9_blur.show()